package test.algos.sorting;

import static test.algos.sorting.input.InputData.INPUT_DATA;

public class SelectionSort implements Sort {

	@Override
	  public void sort() {

	    System.out.println("Soter Input:" + INPUT_DATA);

	    Integer temp = null;
	    for (int i = 0; i < INPUT_DATA.size(); i++) {
	      for (int j = i + 1; j < INPUT_DATA.size(); j++) {
	        if (INPUT_DATA.get(j) < INPUT_DATA.get(i)) {
	          temp = INPUT_DATA.get(i);
	          INPUT_DATA.set(i, INPUT_DATA.get(j));
	          INPUT_DATA.set(j, temp);

	        }
	      }

	    }

	    System.out.println("Sorter Output:" + INPUT_DATA);

	  }

}
